<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <div data-id="1" data-v-497ea84c="不知道">1</div>
    <div>2</div>
    <div>3</div>
    <div>4</div>
    <div>5</div>
    <script>
        // 获取元素
        const one = document.querySelector('div');
        // 获取自定义属性的集合
        console.log(one.dataset);
        // 获取自定义属性的集合中特定的属性
        console.log(one.dataset.id);
        console.log(one.dataset['v-497ea84c']);
    </script>
</body>

</html>